﻿using System;
using System.ComponentModel;
using DevExpress.Xpo;
using DevExpress.Data.Filtering;
using DevExpress.ExpressApp;
using DevExpress.Persistent.Base;
using DevExpress.Persistent.BaseImpl;
using DevExpress.Persistent.Validation;
namespace Top.Module.Domain
{
    [DefaultClassOptions]
    public class TopTask : BaseObject
    {
        //begin
        public TopTask(Session session) : base(session)
        {}
        public override void AfterConstruction(){base.AfterConstruction();}

        private string _DownloadUrl;
        [Size(SizeAttribute.Unlimited)]
        public string DownloadUrl
        {
            get
            {
                return _DownloadUrl;
            }
            set
            {
                SetPropertyValue("DownloadUrl", ref _DownloadUrl, value);
            }
        }
        private string _TaskId;
        [Size(SizeAttribute.Unlimited)]
        public string TaskId
        {
            get
            {
                return _TaskId;
            }
            set
            {
                SetPropertyValue("TaskId", ref _TaskId, value);
            }
        }
        private string _Status;
        [Size(SizeAttribute.Unlimited)]
        public string Status
        {
            get
            {
                return _Status;
            }
            set
            {
                SetPropertyValue("Status", ref _Status, value);
            }
        }
        [Association("TaskSubtasks", typeof(TopSubtask))]
        public XPCollection Subtasks
        {
            get
            {
                return GetCollection("Subtasks");
            }
        }
        private string _Method;
        [Size(SizeAttribute.Unlimited)]
        public string Method
        {
            get
            {
                return _Method;
            }
            set
            {
                SetPropertyValue("Method", ref _Method, value);
            }
        }
        private DateTime _Created;
        public DateTime Created
        {
            get
            {
                return _Created;
            }
            set
            {
                SetPropertyValue("Created", ref _Created, value);
            }
        }
        //end
    }
}
